package cn.wolfcode.shop.cloud.feign;

import cn.wolfcode.shop.cloud.common.Result;
import cn.wolfcode.shop.cloud.domain.Good;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;
import java.util.Set;
//要调用商品服务
@FeignClient(name ="goods-server",fallback = GoodFeignHystrix.class)
//降级的配置
public interface GoodFeignApi {
    @RequestMapping("/queryByGoodIds")
    Result<List<Good>> queryByGoodIds(@RequestParam("goodIds") Set<Long> goodIds);
}
